package pl.ericpol.environment.sensors.move_sensors;

import pl.ericpol.environment.sensors.Sensor;

public abstract class MoveSensor implements Sensor {
	
	int id;
	
	public MoveSensor(int id) {
		super();
		this.id = id;
	}

	abstract public boolean getConcreteState();
	
	@Override
	public long getState() {
		boolean result = getConcreteState();
		if (result)
			return 1;
		else
			return 0;
	}
	
	@Override
	public int getId() {
		return id;
	}
	
	@Override
	public void setId(int id) {
		this.id = id;
	}	
	
}
